;(function(){
	var year=new Date().getFullYear();       
	var sel = document.getElementById('sel');
   for ( var i = year; i >= 2001; i--) {
       var option = document.createElement('option');
       option.value = i;
       var txt = document.createTextNode(i);
       option.appendChild(txt);
       sel.appendChild(option);
   }
})()
var date=getQueryString('date');
$("#sel").change(function(){
	var val=$("#sel option:selected").val();
	var obj=parseURL(window.location.href);
	var params="";
	obj.params.page=1;
	obj.params.date=val;
	var m=0;
	for(var i in obj.params){
		if(m==0){
			params+=(i+'=' + obj.params[i]);
		}else{
			params+=('&'+ i+'=' + obj.params[i]);
		}
		m++;
	}
	var url='http://' + obj.host + ':' + obj.port + obj.path + '?' + params;
	window.location.href=url;
})

if(date){
	$("#sel option").each(function(){
		if($(this).text()==date){
			$(this).prop('selected','selected');
			return false;
		}
	})
}